@model SF.Module.Backend.ViewModels.HomeViewModel

@{
    ViewData["Title"] = "开发框架在线演示";
    Layout = "~/Views/Shared/_Layout.cshtml";
}

@*@await Html.PartialAsync("_WidgetInstances", Model.WidgetInstances.Where(x => x.WidgetZoneId == WidgetZoneIds.HomeFeatured))

    @await Html.PartialAsync("_WidgetInstances", Model.WidgetInstances.Where(x => x.WidgetZoneId == WidgetZoneIds.HomeMainContent))

    @await Html.PartialAsync("_WidgetInstances", Model.WidgetInstances.Where(x => x.WidgetZoneId == WidgetZoneIds.HomeAfterMainContent))
    @* 测试多语言 *@
@*<h3>@ViewData["Message"]</h3>*@
@*<div>
        <h2 class="page-header">Sample data</h2>
        <h1>Delete all current catalog data and create sample catalog</h1>
        <form asp-controller="SampleData" asp-action="ResetToSample" method="post">
            <button type="submit" class="btn btn-danger">Do it!</button>
        </form>
    </div>*@
@*<sf-captcha asp-captcha-generator-max="9000"
    asp-captcha-generator-min="1"
    asp-captcha-generator-language="English"
    asp-placeholder="Security code as a number"
    asp-validation-error-message="Please enter the security code as a number."
    asp-font-name="Tahoma"
    asp-font-size="20"
    asp-fore-color="black"
    asp-back-color="#ccc"
    asp-text-box-class="text-box single-line form-control col-md-4"
    asp-text-box-template="<div class='input-group col-md-4'><span class='input-group-addon'><span class='glyphicon glyphicon-lock'></span></span>{0}</div>"
    asp-validation-message-class="text-danger"
    asp-area-name="" />*@

<div class="mainContent"><iframe width="100%" src="/Home/Default" name="iframepage" id="iframepage" frameborder="no" scrolling="auto" noresize="noresize"></iframe></div>
<script type="text/javascript">
    $(document).ready(function () {
        iframeHeight();
        $(window.parent).resize(function () { //改变窗口或屏幕大小
            iframeHeight();
        });

    });

    function iframeHeight() { //内容区高度
        var winHeight = $(window).height();
        var footerHeight = $('footer').height();
        var headHeight = $('header').height();
        $('#iframepage').height(winHeight - headHeight - footerHeight);
    }
</script>

<style>
    body {
        height: 100%;
        max-height: 100%;
    }

    body {
        overflow: hidden;
    }
</style>